<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改查看作业')" />
    <th:block th:include="include :: summernote-css" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-Stuhomework-edit" th:object="${sStudentHomework}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group" style="display: none;">
                <label class="col-sm-3 control-label">学生id：</label>
                <div class="col-sm-8">
                    <input name="studentId" th:field="*{studentId}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">学生姓名：</label>
                <div class="col-sm-8">
                    <input name="studentName" th:field="*{studentName}" readonly class="form-control" type="text">
                </div>
            </div>
            <div class="form-group" style="display: none;">
                <label class="col-sm-3 control-label">作业id：</label>
                <div class="col-sm-8">
                    <input name="homeworkId" th:field="*{homeworkId}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">作业标题：</label>
                <div class="col-sm-8">
                    <input name="homeworkTitle" th:field="*{homeworkTitle}" readonly  class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">作业内容：</label>
                <div class="col-sm-8">
                    <div th:utext="${{sStudentHomework.homeworkContent}}"></div>
<!--                    <div class="summernote" id="homeworkContent"></div>-->
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">作业评分：</label>
                <div class="col-sm-8">
                    <input name="homeworkScore" th:field="*{homeworkScore}" class="form-control" type="number">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">评分意见：</label>
                <div class="col-sm-8">
                    <textarea name="remark" th:field="*{remark}" id="remark" cols="7" rows="5" class="form-control"></textarea>
                </div>
            </div>
        </form>
    </div>
    <th:block th:include="include :: footer" />
    <th:block th:include="include :: summernote-js" />
    <script th:inline="javascript">
        var prefix = ctx + "homework/Stuhomework";
        $("#form-Stuhomework-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-Stuhomework-edit').serialize());
            }
        }


    </script>
</body>
</html>